package com.order.config;

import org.springframework.cloud.client.loadbalancer.LoadBalanced;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
import org.springframework.web.client.RestTemplate;
@Configuration
public class RestConfig {
    @Bean
    @LoadBalanced//根据服务名调用
    public RestTemplate restTemplate(){//http调用

        return  new RestTemplate();
    }
}
